<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
	<title>勤工需求管理列表</title>
	<meta name="decorator" content="default"/>
	<script type="text/javascript">
		$(document).ready(function() {
			
		});
		function page(n,s){
			$("#pageNo").val(n);
			$("#pageSize").val(s);
			$("#searchForm").submit();
        	return false;
        }
	</script>
	<script type="text/javascript"> //去除重复下列框
    $(function () {
        $("select").each(function (i, n) {
            var options = "";
            $(n).find("option").each(function (j, m) {
                if (options.indexOf($(m)[0].outerHTML) == -1) {
                    options += $(m)[0].outerHTML;
                }
            });
            $(n).html(options);
        });
    });
	</script>
</head>
<body>
	<ul class="nav nav-tabs">
		<li class="active"><a href="${ctx}/jobmesmanage/schoStuwork/">勤工需求管理列表</a></li>
		<shiro:hasPermission name="jobmesmanage:schoStuwork:edit"><li><a href="${ctx}/jobmesmanage/schoStuwork/form">勤工需求管理添加</a></li></shiro:hasPermission>
	</ul>
	<form:form id="searchForm" modelAttribute="schoStuwork" action="${ctx}/jobmesmanage/schoStuwork/" method="post" class="breadcrumb form-search">
		<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
		<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
		<ul class="ul-form">
			<li><label>业务名称：</label>
				<form:select path="styleId" class="input-medium">
					<form:option value="" label=""/>
					<form:options items="${schoStuworks}" itemLabel="redStype" itemValue="styleId" htmlEscape="false"/>
				</form:select>
			</li>
			<li><label>需求方名称：</label>
				<form:input path="reqName" htmlEscape="false" maxlength="30" class="input-medium"/>
			</li>
			<li><label>岗位要求：</label>
				<form:input path="reqNeed" htmlEscape="false" maxlength="512" class="input-medium"/>
			</li>
			<li><label>劳酬：</label>
				<form:input path="reqPay" htmlEscape="false" maxlength="11" class="input-medium"/>
			</li>
			<li><label>联系电话：</label>
				<form:input path="reqPhone" htmlEscape="false" maxlength="11" class="input-medium"/>
			</li>
			<li><label>工作地址：</label>
				<form:input path="reqAddr" htmlEscape="false" maxlength="255" class="input-medium"/>
			</li>
			<li><label>状态：</label>
				<form:select path="reqStates" class="input-medium">
					<form:option value="" label=""/>
					<form:options items="${fns:getDictList('req_status')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
				</form:select>
			</li>
			<li class="btns"><input id="btnSubmit" class="btn btn-primary" type="submit" value="查询"/></li>
			<li class="clearfix"></li>
		</ul>
	</form:form>
	<sys:message content="${message}"/>
	<table id="contentTable" class="table table-striped table-bordered table-condensed">
		<thead>
			<tr>
				<th>业务名称</th>
				<th>需求方名称</th>
				<th>勤工内容</th>
				<th>劳酬</th>
				<th>提供服利说明</th>
				<th>联系地址</th>
				<th>联系电话</th>
				<th>状态</th>
				<shiro:hasPermission name="jobmesmanage:schoStuwork:edit"><th>操作</th></shiro:hasPermission>
			</tr>
		</thead>
		<tbody>
		<c:forEach items="${page.list}" var="schoStuwork">
			<tr>
				<td>
                    ${schoStuwork.redStype}
				</td>
				<td><a href="${ctx}/jobmesmanage/schoStuwork/form?id=${schoStuwork.id}">
					${schoStuwork.reqName}
				</a></td>
				<td>
					${schoStuwork.reqContent}
				</td>
				<td>
					${schoStuwork.reqPay}
				</td>
				<td>
					${schoStuwork.reqStatement}
				</td>
				<td>
						${schoStuwork.reqAddr}
				</td>
				<td>
					${schoStuwork.reqPhone}
				</td>
				<td>
                    ${fns:getDictLabel(schoStuwork.reqStates, 'req_status',schoStuwork.id)}
				</td>
				<shiro:hasPermission name="jobmesmanage:schoStuwork:edit"><td>
    				<a href="${ctx}/jobmesmanage/schoStuwork/form?id=${schoStuwork.id}">修改</a>
					<a href="${ctx}/jobmesmanage/stuJobSearch/detail?joblinkid=${schoStuwork.id}">查看报名</a>
					<a href="${ctx}/jobmesmanage/schoStuwork/delete?id=${schoStuwork.id}" onclick="return confirmx('确认要删除该勤工详情吗？', this.href)">删除</a>
				</td></shiro:hasPermission>
			</tr>
		</c:forEach>
		</tbody>
	</table>
	<div class="pagination">${page}</div>
</body>
</html>